compareplot.confrontational <- function (out_org,
                                         out_mar,
                                         out_leg_cut,
                                         legend.names=c("Missing as zero", "Missing at random", "Indifference model")) {
  windows(10,7)
  # Make plot (Figure 3)
  o <- out_org$actors_summary
  n = dim(o)[1]
  labelcex=.8
  
  plot( x=c(floor(min(o[,2])*1.05),ceiling(max(o[,3])*1.05)),
        y=c(0.25,n+.75),
        yaxs="i",
        xlab="",
        ylab="",
        type="n",
        yaxt="n",
        axes=FALSE, main="")
  
  
  indx = order(o[,1])
  segments(x0=o[indx,2],
           x1=o[indx,3],
           y0=1:n,y1=1:n, col="grey50")
  points(x=o[indx,1],
         y=1:n,
         cex=1,
         col="red",
         pch=16,
         xpd=NA)
  
  
  o2 <- out_mar$actors_summary
  indx2 = order(o2[,1]) 
  offset2 <- .18
  
  segments(x0=o2[indx2,2],
           x1=o2[indx2,3],
           y0=1:n+offset2,y1=1:n+offset2, col="grey50")
  
  points(x=o2[indx2,1],
         y=1:n+offset2,
         cex=1,
         col="blue",
         pch=17,
         xpd=NA)
  
  
  
  o3 <- out_leg_cut$actors_summary
  indx3 = order(o3[,1]) 
  offset3 <- .36
  
  segments(x0=o3[indx3,2],
           x1=o3[indx3,3],
           y0=1:n+offset3,y1=1:n+offset3, col="grey50")
  
  points(x=o3[indx3,1],
         y=1:n+offset3,
         cex=1,
         col="darkgreen",
         pch=18,
         xpd=NA)
  
  
  
  ## label
  for(i in 1:n) {
    if(o2[indx[i],1]<0) {
      text(y=i+offset2,x=o2[indx2[i],3],
           pos=4,cex=labelcex,labels=dimnames(o)[[1]][indx[i]]) }
    else {
      text(y=i+offset2,x=o2[indx2[i],2],
           pos=2,cex=labelcex,dimnames(o)[[1]][indx[i]])     
    }
  }
  axis(1)
  axis(3)
  abline(v=0, lty=2, col="grey")
  
  
  legend("bottomright", legend=legend.names, pch=c(16,17,18), col=c("red","blue","darkgreen"))
}